Fix or silence ruff check warnings; add ruff check to Github Actions#246
Merged
bnavigator merged 3 commits intopython-control:masterfrom Feb 1, 2025
Merged
Fix or silence ruff check warnings; add ruff check to Github Actions#246bnavigator merged 3 commits intopython-control:masterfrom
ruff check warnings; add ruff check to Github Actions#246bnavigator merged 3 commits intopython-control:masterfrom
Conversation
Removed unused imports. Removed unused variables in test: these were cut-and-paste from other tests, and not needed for the tests in questions. Other minor fixes.
Collaborator
|
I like the general approach! Thanks @roryyorke! I would prefer not to override E741 (ambigous variable name) on single lines. I'd rather just switch it off globally. We use the single letter variable names where SLICOT uses them. |
bnavigator
requested changes
Jan 30, 2025
slycot/analysis.py
Outdated
|
|
||
|
|
||
| def ag08bd(l,n,m,p,A,E,B,C,D,equil='N',tol=0.0,ldwork=None): | ||
| def ag08bd(l,n,m,p,A,E,B,C,D,equil='N',tol=0.0,ldwork=None): # noqa: E741 |
Collaborator
There was a problem hiding this comment.
Just switch off E741 in a global option in pyproject.toml
[tool.ruff.lint]
ignore = [ "E741" ]
Collaborator
Author
There was a problem hiding this comment.
Done. If it weren't backward incompatible I'd be tempted to change l to ell, but so it goes.
Collaborator
Author
|
From what I see, all failures are on macos, and I think all macos jobs fail. I checked two at random, and the failure is in python-control TestStateSpace.test_pow: |
Collaborator
Author
|
not all macos tests fail; many pass, but 7 fail. |
Collaborator
|
Failing macOS tests are unrelated. Thanks @roryyorke |
Closed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Is this worth it at all?
Are the particular fixes I've made (especially
# noqaones) reasonable?